import { $get, $post } from '@js/request'
import { AccountSchema } from '@components/schema/account'

// 获取人员列表
export async function getPersonListRequest (): Promise<AccountSchema[]> {
  const res = await $get('/api/common/employee', {
    page: 1,
    limit: 10000
  })
  return res.data.list
}

// 新增人员
export async function addRequest (performanceid: string, d: { [k: string]: any }): Promise<void> {
  const res = await $post('/api/commission/performance_work', {
    ...d,
    performanceid
  })
  return res.data
}
